﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="prescription_list.aspx.cs" Inherits="MxWeiXinPF.Web.admin.users.prescription_list" %>

<%@ Import namespace="MxWeiXinPF.Common" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>处方审核</title>
    <script type="text/javascript" src="/scripts/jquery/jquery-1.10.2.min.js"></script>
    <script type="text/javascript" src="/scripts/lhgdialog/lhgdialog.js?skin=idialog"></script>
    <script type="text/javascript" src="/admin/js/layout.js"></script>
    <link  href="/admin/css/pagination.css" rel="stylesheet" type="text/css" />
    <link href="/admin/skin/default/style.css" rel="stylesheet" type="text/css" />
</head>
<script type="text/javascript">

    function ShowElement(id) {
        var elem = document.getElementById(id);
        elem.style.display = "block";
    }

    function HideElement(id) {
        var elem = document.getElementById(id);
        elem.style.display = "none";
    }
   
</script> 

<body class="mainbody">
    <form id="form1" runat="server">
    <!--导航栏-->
    <div class="location">
        <a href="javascript:history.back(-1);" class="back"><i></i><span>返回上一页</span></a>
        <a href="../center.aspx" class="home"><i></i><span>首页</span></a> <i class="arrow">
        </i><span>处方审核列表</span>
    </div>
    <!--/导航栏-->
    <!--工具栏-->
    <div class="toolbar-wrap">
        <div id="floatHead" class="toolbar">
            <div class="l-list">  
           <div class="rule-single-select">
                        <asp:DropDownList ID="ddlStatus" runat="server" OnSelectedIndexChanged="ddlStatus_SelectedIndexChanged2">
                            <asp:ListItem Value="" Selected="True">请选择</asp:ListItem>
                            <asp:ListItem Value="0">未审核</asp:ListItem>
                            <asp:ListItem Value="1">已审核</asp:ListItem>
                        </asp:DropDownList>
                    </div>         
            </div>
            <div class="r-list">
                <asp:TextBox ID="txtKeywords" runat="server" CssClass="keyword" />
                <asp:LinkButton ID="lbtnSearch" runat="server" CssClass="btn-search" OnClick="btnSearch_Click2">查询</asp:LinkButton>
            </div>
        </div>
    </div>
    <!--/工具栏-->
    <!--列表-->
    <asp:Repeater ID="rptList" runat="server" onitemcommand="rptList_ItemCommand">
        <HeaderTemplate>
            <table width="100%" border="0" cellspacing="0" cellpadding="0" class="ltable">
                <tr>
                    <th width="8%">
                        选择
                    </th>
                    <th>
                        处方说明
                    </th>
                    <th>
                        处方照片
                    </th>
                    <th>
                        上传人
                    </th>
                     <th>
                        联系方式
                    </th>
                   <th>
                        上传时间
                    </th> 
                    <th>
                        审核状态
                    </th> 
                     <th>
                        审核时间
                    </th>  
              
                    <th>
                        操作
                    </th>
                </tr>
        </HeaderTemplate>
        <ItemTemplate>
            <tr>
                <td align="center">
                    <asp:CheckBox ID="chkId" CssClass="checkall" runat="server" /><asp:HiddenField ID="hidId"
                        Value='<%#Eval("id")%>' runat="server" />
                </td>
                <td align="center">
                    <a href="userbbsdetail_edit.aspx?action=<%#MXEnums.ActionEnum.Edit %>&id=<%#Eval("id")%>"><%#Eval("title")%></a>
                </td>                      
                <td align="center">
                    <%#Eval("url").ToString() != "" ? "<img width=\"64\" height=\"64\" src=\"" + Eval("url") + "\" onmouseover=\"ShowElement('" + Eval("id") + "');\" onmouseout=\"HideElement('" + Eval("id") + "');\"   />" : "<b class=\"user-avatar\"></b>"%>
                  <div style="position:relative;"><div id="<%#Eval("id")%>" onmouseout="HideElement(<%#Eval("id")%>)" style="position:absolute;display:none"><%#Eval("url").ToString() != "" ? "<img width=\"500\" height=\"500\" src=\"" + Eval("url") + "\" onmouseout=\"HideElement('" + Eval("id") + "');\"   />" : "<b class=\"user-avatar\"></b>"%></div></div>
                </td>
                 <td align="center">
                    <%#Eval("nick_name")%>
                </td>
                   <td align="center">
                    <%#Eval("mobile")%>
                </td>
                 <td align="center">
                    <%#string.Format("{0:d}",Eval("createtime"))%>
                </td> 
                <td align="center">
                    <%# GetStatus(Eval("id").ToString())%>
                </td>
                  <td align="center">
                    <%#string.Format("{0:d}",Eval("audittime"))%>
                </td> 
                  <td align="center">
                      <asp:LinkButton ID="lkbAudit_Pass" runat="server" Visible='<%# Eval("status").ToString().Equals("0")%>' CommandArgument='<%#Eval("id") %>' OnClientClick="return confirm('是否审核通过')" CommandName="audit_pass"  >审核</asp:LinkButton> 
                      <asp:LinkButton ID="lkbAudit_Refuse" runat="server" Visible='<%# Eval("status").ToString().Equals("0")%>' CommandArgument='<%#Eval("id") %>' OnClientClick="return confirm('是否拒绝')" CommandName="audit_refuse"  >拒绝</asp:LinkButton> 
                  </td>  
            </tr>
        </ItemTemplate>
        <FooterTemplate>
            <%#rptList.Items.Count == 0 ? "<tr><td align=\"center\" colspan=\"9\">暂无记录</td></tr>" : ""%>
            </table>
        </FooterTemplate>
    </asp:Repeater>   
    <!--/列表-->
    </form>
</body>
</html>
